package com.core.controller.test;

import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class PermissionTestController {
    @RequestMapping(value = "/userList",method = RequestMethod.GET)
    @RequiresPermissions(value = {"user:list"})
    public String userList(){
        return "userList";
    }

    @RequestMapping(value = "/userManager",method = RequestMethod.GET)
    @RequiresPermissions(value = {"user:manage"})
    public String userManager(){
        return "userManager";
    }
}
